package com.wan37.auth.service.impl;

import com.wan37.auth.dao.UserDao;
import com.wan37.auth.domain.User;
import com.wan37.auth.service.LoginService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author : luoyong
 * @date : 2020-05-27 17:12
 **/
@Service("loginService")
public class LoginServiceImpl implements LoginService {

    @Autowired
    private UserDao userDao;

    @Override
    public User getUserByUserId(String userId) {
        User user = userDao.getUserByUserId(userId);
        if (user != null) {
            return user;
        } else {
            return null;
        }
    }
}
